package novel.factory;

import novel.enums.NovelSpiderEnum;
import novel.impl.chapter.DefaultChapterDetilSpider;
import novel.intrerfaces.IchapterDetailSpider;

/**
 * @Author:xdw
 * @Date:Created in 上午 9:342019/3/13 0013
 * @described:
 * @Modified By:
 */
public class ChapterDetailSpiderFactory {
    private ChapterDetailSpiderFactory() {}

    public static IchapterDetailSpider getChapterDetailSpider(String url){
        IchapterDetailSpider chapterDetailSpider=null;

        NovelSpiderEnum novelSpiderEnum = NovelSpiderEnum.getEnumByUrl(url);
        switch (novelSpiderEnum) {
            case BI_QU_GE:
            case DING_DIAN_WX:
                chapterDetailSpider = new DefaultChapterDetilSpider();
                break;
        }

        return chapterDetailSpider;

    }
}
